{template 'header'}
<link href="{MODULE_URL}template/css/css.css" rel="stylesheet" />
<link href="{MODULE_URL}template/css/stylesheet.css" rel="stylesheet" />
<div class="top_menu">
    小区商家
</div>
<div class="top_menu_shadow"></div>
<div id='list'>
{loop $list $item}
<div class="fy">
    <a href="{if $item['businessurl']}{$item['businessurl']}{else}{php echo $this->createMobileUrl('business',array('op'=> 'detail','id'=> $item['id']))}{/if}" class="sq_box commodity">
        <div class="commodity_img">
            <img src="{if $item['picurl']}{$_W['attachurl']}{$item['picurl']}{else}{MODULE_URL}template/image/Nopictures.jpg{/if}" />

        </div>
        <div class="commodity_content">
            <div class="commodity_content_info">
                <div class="content_info_l">
                    <div class="info_l_x"></div>
                    <div class="info_l_s"><span>{$item['sjname']}</span>
                    </div>
                    <div class="info_l_x">
                        <span class="unread">
                            {$item['address']}
                        </span>
                    </div>
                </div>
              
            </div>
            <div class="commodity_address">
                <span class="comm_add">
					{$item['mobile']}
				</span>
            </div>
        </div>
    </a>
    <div class="commodity_fbxx">
        <div class="commodity_time">


            <font color="blue"></font>{php echo date('Y-m-d H:i:s', $item['createtime'])}


        </div>
    </div>

</div>
{/loop}			
</div>
<div style="display:none;left: 0px;top: 0px;width: 100%;height: 100%;overflow: hidden;position: fixed;background: rgba(0, 0, 0, 0.5);" id="layer">

</div>
{if count($list)>9}
<div style="margin-top:20px;margin-bottom:70px;text-align:center;font-size:16px;" id='view' >查看更多</div>
{/if}
<script>
var page = 2;
$(function() {
    $("#view").click(function() {
        $('#layer').show();
        obj=$(this);
        $(this).html('正在加载中...')
        $.get("{php echo $this->createMobileUrl('business',array('op'=>'more'))}&page="+page, function(result){
                    if(result!=''){
                        $('#list').append(result);
                        page++;    
                        obj.html('查看更多');
                    }else{
                        obj.hide();
                    }
                    $('#layer').hide();
            });
        });
});
</script>


{template 'footer'}